<!-- views/StudentList.vue -->
<template>
    <div>
      <h1>学生列表</h1>
      <ul>
        <li v-for="student in students" :key="student.id">
          <router-link :to="{ name: 'StudentDetail', params: { id: student.id } }">
            {{ student.name }}
          </router-link>
        </li>
      </ul>
    </div>
</template>
  
<script>
  export default {
    data() {
      return {
        students: [
          { id: 1, name: '张三' },
          { id: 2, name: '李四' },
          // 其他学生数据
        ],
      };
    },
  };
</script>
  